#pragma once

struct FSMCartridge
{
	//attributes
	int m_selfId;
	int m_swapId;
	char m_name[32];
	bool m_completed;
	bool m_loaded;
	bool m_renew;
	void* m_data;

	//ctor & dtor
	FSMCartridge()
	{
		m_selfId = -1;
		m_swapId = -1;

		for(int i = 0; i < 32; i++)
			m_name[i] = 0;

		m_completed = false;
		m_loaded    = false;
		m_renew     = true;
		m_data      = 0;
	}
	~FSMCartridge(){release();}

	//main functions
	virtual void init(){}
	virtual void reset(){}
	virtual void release(){}
	virtual void input(){}
	virtual void update(){}
	virtual void draw(){}
	virtual void pre(){}
	virtual void post(){}

	//getter functions
	bool completed(){return m_completed;}
	bool loaded(){return m_loaded;}
	bool renew(){return m_renew;}
};